from pathlib import Path

# 项目根目录：假设 config.py 在项目根目录
BASE_DIR = Path(__file__).resolve().parent
MAX_FILE_SIZE_MB = 2  # 最大2MB
# 配置路径
AVATAR_DIR = BASE_DIR / "media" / "avatars"
SCRIPT_DIR = BASE_DIR / "media" / "scripts"
REPORT_DIR = BASE_DIR / "media" / "reports"
AVATAR_DIR.mkdir(parents=True, exist_ok=True)  # 创建目录

# JWT 等常量
SECRET_KEY = "sadsknjakdnajmkdnjefvdsrkmal"
ALGORITHM = "HS256"
ACCESS_TOKEN_EXPIRE_MINUTES = 240
